
<h1><span class="yiyi-st" id="yiyi-12">numpy.less</span></h1>
        <blockquote>
        <p>原文：<a href="https://docs.scipy.org/doc/numpy/reference/generated/numpy.less.html">https://docs.scipy.org/doc/numpy/reference/generated/numpy.less.html</a></p>
        <p>译者：<a href="https://github.com/wizardforcel">飞龙</a> <a href="http://usyiyi.cn/">UsyiyiCN</a></p>
        <p>校对：（虚位以待）</p>
        </blockquote>
    
<dl class="data">
<dt id="numpy.less"><span class="yiyi-st" id="yiyi-13"> <code class="descclassname">numpy.</code><code class="descname">less</code><span class="sig-paren">(</span><em>x1</em>, <em>x2</em><span class="optional">[</span>, <em>out</em><span class="optional">]</span><span class="sig-paren">)</span><em class="property"> = &lt;ufunc &apos;less&apos;&gt;</em></span></dt>
<dd><p><span class="yiyi-st" id="yiyi-14">返回（x1的真值</span></p>
<table class="docutils field-list" frame="void" rules="none">
<col class="field-name">
<col class="field-body">
<tbody valign="top">
<tr class="field-odd field"><th class="field-name"><span class="yiyi-st" id="yiyi-15">参数：</span></th><td class="field-body"><p class="first"><span class="yiyi-st" id="yiyi-16"><strong>x1，x2</strong>：array_like</span></p>
<blockquote>
<div><p><span class="yiyi-st" id="yiyi-17">输入数组。</span><span class="yiyi-st" id="yiyi-18">如果<code class="docutils literal"><span class="pre">x1.shape</span> <span class="pre">！=  t&gt;&gt; <span class="pre">x2.shape</span></span></code>，它们必须可以广播到一个通用形状一个或另一个的形状）。</span></p>
</div></blockquote>
</td>
</tr>
<tr class="field-even field"><th class="field-name"><span class="yiyi-st" id="yiyi-19">返回：</span></th><td class="field-body"><p class="first"><span class="yiyi-st" id="yiyi-20"><strong>out</strong>：bool或ndarray的bool</span></p>
<blockquote class="last">
<div><p><span class="yiyi-st" id="yiyi-21">如果<em class="xref py py-obj">x1</em>和<em class="xref py py-obj">x2</em>是标量，则bool的数组或单个bool。</span></p>
</div></blockquote>
</td>
</tr>
</tbody>
</table>
<div class="admonition seealso">
<p class="first admonition-title"><span class="yiyi-st" id="yiyi-22">也可以看看</span></p>
<p class="last"><span class="yiyi-st" id="yiyi-23"><a class="reference internal" href="numpy.greater.html#numpy.greater" title="numpy.greater"><code class="xref py py-obj docutils literal"><span class="pre">greater</span></code></a>，<a class="reference internal" href="numpy.less_equal.html#numpy.less_equal" title="numpy.less_equal"><code class="xref py py-obj docutils literal"><span class="pre">less_equal</span></code></a>，<a class="reference internal" href="numpy.greater_equal.html#numpy.greater_equal" title="numpy.greater_equal"><code class="xref py py-obj docutils literal"><span class="pre">greater_equal</span></code></a>，<a class="reference internal" href="numpy.equal.html#numpy.equal" title="numpy.equal"><code class="xref py py-obj docutils literal"><span class="pre">equal</span></code></a>，<a class="reference internal" href="numpy.not_equal.html#numpy.not_equal" title="numpy.not_equal"><code class="xref py py-obj docutils literal"><span class="pre">not_equal</span></code></a></span></p>
</div>
<p class="rubric"><span class="yiyi-st" id="yiyi-24">例子</span></p>
<div class="highlight-default"><div class="highlight"><pre><span></span><span class="gp">&gt;&gt;&gt; </span><span class="n">np</span><span class="o">.</span><span class="n">less</span><span class="p">([</span><span class="mi">1</span><span class="p">,</span> <span class="mi">2</span><span class="p">],</span> <span class="p">[</span><span class="mi">2</span><span class="p">,</span> <span class="mi">2</span><span class="p">])</span>
<span class="go">array([ True, False], dtype=bool)</span>
</pre></div>
</div>
</dd></dl>
